home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 49 / Amiga Format CD49 (2000-01-17)(Future Publishing)(GB)(Track 1 of 3)[!][issue 2000-02].iso / -serious- / sound / playgui / playinfo < prev    next >
Text File  |  1999-11-30  |  2KB  |  97 lines

  1. G4C;PlayINFO by Richard Kapp 1999 ; MUST BE IN THE FIRST(!) LINE
  2. WINBIG 0 0 275 170 ""
  3. wintype 00001000
  4. image 0 0 book
  5. WINFONT topaz_thin.font 8 000
  6. WINBACKGROUND image info 0
  7.  
  8. xonload
  9.         templ = no
  10.         unit = 0
  11.         
  12.        
  13.         loadimage book info Workbench
  14.         guiopen PlayInfo
  15.  
  16.  
  17. xonclose
  18.         freeimage book
  19.         guiquit PlayInfo
  20.  
  21.  
  22. xBUTTON 184 140 40 15 "OKAY"
  23. freeimage book
  24. guiquit PlayInfo
  25.  
  26. XBUTTON 244 8 20 15 ">"
  27. ++unit
  28. gosub PlayInfo changeunit
  29.  
  30. XBUTTON 220 8 20 15 "<"
  31. --unit
  32. gosub PlayInfo changeunit
  33.  
  34. XTEXTIN 338 3 58 14 "" unit '0' 10
  35. gadid 2
  36. gosub PlayInfo changeunit
  37.  
  38. xRoutine ChangeUnit
  39. ; make sure the unit is 0-255
  40. if $unit > 255
  41.    unit = 0
  42. elseif $unit < 0
  43.    unit = 255
  44. endif
  45.  
  46.  
  47. lvuse PlayInfo 1
  48. lvchange "CLIPS:$unit"
  49. update PlayInfo 2 $unit
  50.  
  51. xBUTTON 175 30 60 15 "LOAD"
  52. ReqFile  -1 -1 300 -30 'Choose file :' LOAD filename ''
  53. if $filename > ''
  54.    lvuse PlayInfo 1
  55.    lvchange $filename
  56.    ; now save it so as to write it to the clipboard
  57.    lvsave 'CLIPS:$unit'
  58. endif
  59.  
  60. xBUTTON 175 50 60 15 "SAVE"
  61. ReqFile  -1 -1 300 -30 'Save as file :' SAVE savename ''
  62. if $savename > ' '
  63.    ifexists file $savename
  64.       ezreq 'File $savename exists.\nOverwrite ?' Overwrite|CANCEL choice
  65.       if $choice = 0
  66.          stop
  67.       endif
  68.    endif
  69.    lvsave $savename
  70. endif
  71.  
  72. XBUTTON 175 70 60 15 "CLEAR"
  73. lvuse PlayInfo 1
  74. lvclear
  75. lvsave 'CLIPS:$unit'
  76.  
  77. XLISTVIEW 15 45 100 120 "" clipline CLIPS:0 10 NUM
  78. gadid 1
  79.  
  80. xBUTTON 175 90 60 15 "EDIT"
  81. if $templ = no
  82. CLI 'C:copy PlayGUI:template.txt ram:t'
  83. CLI 'C:run >NIL: C:ed ram:t/template.txt'
  84. templ = yes
  85. elseif $templ = yes
  86. CLI 'C:run >NIL: C:ed ram:t/template.txt'
  87. endif
  88.  
  89. xBUTTON 175 110 60 15 "HELP"
  90. EZReq "You can write and edit your info via ED and view, save and load it here." "AHA" helpy
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.